@import "../../../base/less/mixins";

@button_width: '';
@has_button_width: false;
@button_color: #41a9d5;
@border_color: darken(@button_color, 15%);
@text_color: #FFFFFF;

@font_size: 1em;
@rounding: 0.25em;
@padding: 1em;
@has_text: true;

.ow-button-base {

	a {
		.box-sizing(border-box);
		.btn_width() when( @has_button_width = true) {
			width: @button_width;
		}
		.btn_width();

		font-size: @font_size;
		padding: @padding @padding*2;
		.gradient(@button_color, darken(@button_color, 10%), @button_color);
		border: 1px solid;
		border-color: lighten(@border_color, 2%) @border_color darken(@border_color, 3%) @border_color;

		color: @text_color !important;

		.rounded(@rounding);

		.box-shadow(~"inset 0 1px 0 rgba(255,255,255,0.2), 0 1px 2px rgba(0,0,0,0.065)");
		text-shadow: 0 1px 0 rgba(0,0,0,0.05);

        .sow-icon-image,
        [class^="sow-icon-"] {
            .icon-margins() when (@has_text = true) {
                margin: -0.1em 0.75em -0.2em -0.75em;
            }
            .icon-margins() when not (@has_text = true) {
                margin: 0;
            }
            .icon-margins();
        }

		&:visited,
		&:active,
		&:hover{
			color: @text_color !important;
		}

		&.ow-button-hover:hover {
			.gradient(lighten(@button_color, 2%), lighten(darken(@button_color, 10%), 2%), lighten(@button_color, 2%));
			border-color: lighten(lighten(@border_color, 2%), 2%) lighten(@border_color, 2%) darken(lighten(@border_color, 2%), 3%) lighten(@border_color, 2%);
			color: lighten(@text_color, 2%);
		}
	}
}
